package edu.gdin.ecommerce.model;

import java.util.Date;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;

/**
 * Customer entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "t_customer", catalog = "ecommerce")
public class Customer implements java.io.Serializable {

	// Fields

	/**
	 * 
	 */
	private static final long serialVersionUID = 7203100965428028131L;
	private Integer customerId;
	private String name;
	private Date birthday;
	private String mobile;
	private String tel;
	private String email;
	private String address;
	private String postcode;
	private String areaProvince;
	private String areaCity;
	private String areaDistrict;
	private Integer certificateType;
	private String certificateNo;
	private Date createTime;
	private Date updateTime;
	private String customerDesc;

	// Constructors

	/** default constructor */
	public Customer() {
	}

	/** full constructor */
	public Customer(String name, Date birthday, String mobile, String tel,
			String email, String address, String postcode, String areaProvince,
			String areaCity, String areaDistrict, Integer certificateType,
			String certificateNo, Date createTime, Date updateTime,
			String customerDesc) {
		this.name = name;
		this.birthday = birthday;
		this.mobile = mobile;
		this.tel = tel;
		this.email = email;
		this.address = address;
		this.postcode = postcode;
		this.areaProvince = areaProvince;
		this.areaCity = areaCity;
		this.areaDistrict = areaDistrict;
		this.certificateType = certificateType;
		this.certificateNo = certificateNo;
		this.createTime = createTime;
		this.updateTime = updateTime;
		this.customerDesc = customerDesc;
	}

	// Property accessors
	@Id
	@GeneratedValue
	@Column(name = "CUSTOMER_ID", unique = true, nullable = false)
	public Integer getCustomerId() {
		return this.customerId;
	}

	public void setCustomerId(Integer customerId) {
		this.customerId = customerId;
	}

	@Column(name = "NAME", nullable = false, length = 20)
	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Temporal(TemporalType.DATE)
	@Column(name = "BIRTHDAY", length = 10)
	public Date getBirthday() {
		return this.birthday;
	}

	public void setBirthday(Date birthday) {
		this.birthday = birthday;
	}

	@Column(name = "MOBILE", nullable = false, length = 15)
	public String getMobile() {
		return this.mobile;
	}

	public void setMobile(String mobile) {
		this.mobile = mobile;
	}

	@Column(name = "TEL", length = 15)
	public String getTel() {
		return this.tel;
	}

	public void setTel(String tel) {
		this.tel = tel;
	}

	@Column(name = "EMAIL", length = 30)
	public String getEmail() {
		return this.email;
	}

	public void setEmail(String email) {
		this.email = email;
	}

	@Column(name = "ADDRESS", length = 100)
	public String getAddress() {
		return this.address;
	}

	public void setAddress(String address) {
		this.address = address;
	}

	@Column(name = "POSTCODE", length = 8)
	public String getPostcode() {
		return this.postcode;
	}

	public void setPostcode(String postcode) {
		this.postcode = postcode;
	}

	@Column(name = "AREA_PROVINCE", nullable = false, length = 20)
	public String getAreaProvince() {
		return this.areaProvince;
	}

	public void setAreaProvince(String areaProvince) {
		this.areaProvince = areaProvince;
	}

	@Column(name = "AREA_CITY", nullable = false, length = 20)
	public String getAreaCity() {
		return this.areaCity;
	}

	public void setAreaCity(String areaCity) {
		this.areaCity = areaCity;
	}

	@Column(name = "AREA_DISTRICT", nullable = false, length = 20)
	public String getAreaDistrict() {
		return this.areaDistrict;
	}

	public void setAreaDistrict(String areaDistrict) {
		this.areaDistrict = areaDistrict;
	}

	@Column(name = "CERTIFICATE_TYPE", nullable = false)
	public Integer getCertificateType() {
		return this.certificateType;
	}

	public void setCertificateType(Integer certificateType) {
		this.certificateType = certificateType;
	}

	@Column(name = "CERTIFICATE_NO", nullable = false, length = 20)
	public String getCertificateNo() {
		return this.certificateNo;
	}

	public void setCertificateNo(String certificateNo) {
		this.certificateNo = certificateNo;
	}

	@Column(name = "CREATE_TIME", nullable = false, length = 19)
	public Date getCreateTime() {
		return this.createTime;
	}

	public void setCreateTime(Date createTime) {
		this.createTime = createTime;
	}

	@Column(name = "UPDATE_TIME", length = 19)
	public Date getUpdateTime() {
		return this.updateTime;
	}

	public void setUpdateTime(Date updateTime) {
		this.updateTime = updateTime;
	}

	@Column(name = "CUSTOMER_DESC", length = 200)
	public String getCustomerDesc() {
		return this.customerDesc;
	}

	public void setCustomerDesc(String customerDesc) {
		this.customerDesc = customerDesc;
	}

}